package com.owen.pojo;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.io.Serializable;

@Data
@AllArgsConstructor
@NoArgsConstructor
@TableName(value = "user")
public class User implements Serializable {

    // id序列化为string,避免Long值太长前端丢失精度
    @JsonFormat(shape = JsonFormat.Shape.STRING)
    @TableId
    private Long id;

    private String name;

    private Integer age;

    private String address;

    private String introduction;
}
